1. Field of Invention
The present invention relates to an image compression method with a variable quantization parameter, and more particularly to an image compression method with a variable quantization parameter which requires less memory space.
2. Related Art
Along with the progress in electronic and information technologies, the technology of processing and displaying images on computers or various electronic devices has developed to be more and more popular. The early electronic information technologies can only store or process low-pixel digital images. Now, people long for high-quality images with more and more demands. In order to obtain high-quality images, a lossless compression method is often employed for image compression. However, a high-quality image generally has a large file size and cannot be stored and propagated conveniently. In this regard, experts in image processing have developed a lossy compression technology, which discards some information of an image to reduce the file size. For example, Joint Photographic Experts Group (JPEG) is the best known lossy compression format.
Lossy compression usually discards some data by means of quantization, and further includes two methods as using a single quantization parameter and using non-uniform quantization parameters. The method of using a single quantization parameter is to quantize all images or all blocks of one image with the same quantization parameter. Thus, the conventional image compression method using a single quantization parameter has a problem that the quantization parameter is not applicable to all images or all blocks in one image. The conventional image compression method using non-uniform quantization parameters emphasizes low-frequency parts in images, so as to represent the low-frequency parts with almost all bits during encoding. However, such method loses most of medium- and high-frequency images visible to human eyes, for example, parts with complex picture composition, with the result that the lost image looks unnatural.
Moreover, some conventional encoders adopt a prediction method such as context modeling, which needs to at least buffer a whole row of pixels of an image so as to perform prediction in various modes. Therefore, the conventional encoders require a large amount of storage space, resulting in an increased cost thereof.
Furthermore, request of users for higher and higher image resolutions aggravates the burden on image compression. If a conventional compression method is adopted, once the image resolution is raised, the encoder needs to consume a larger amount of storage space to store a whole row of pixels in an image for image compression. In other words, the conventional image compression method has the problems that a single quantization parameter is unsuitable for a whole image, medium- and high-frequency information in an image is discarded excessively due to non-uniform quantization parameters, and large buffer space is required.